//
//  ZQBaseModels.m
//  jianzhik
//
//  Created by 黄健文 on 2018/8/20.
//  Copyright © 2018年 WKWebView. All rights reserved.
//

#import "ZQBaseModels.h"
#define kMargin  10
@implementation ZQBaseModels


- (CGFloat)cellHeight
{
    if (_cellHeight) return _cellHeight;
    CGSize textMaxSize = CGSizeMake(232 , MAXFLOAT);
    NSLog(@"self.model.title == %@",self.title);
    // 文字内容高度
    _cellHeight += [self.title boundingRectWithSize:textMaxSize options:NSStringDrawingUsesLineFragmentOrigin attributes:@{NSFontAttributeName : [UIFont systemFontOfSize:19]} context:nil].size.height + 2 * kMargin + kMargin + kMargin;
    
    CGSize textMaxSize1 = CGSizeMake(MAXFLOAT , MAXFLOAT);
    _cellHeight += [self.title boundingRectWithSize:textMaxSize1 options:NSStringDrawingUsesLineFragmentOrigin attributes:@{NSFontAttributeName : [UIFont systemFontOfSize:14]} context:nil].size.height * 2 + 2 * kMargin;
    
    return _cellHeight;
}

@end
